package ua.yandex.skipasssystem.skipass;

import ua.yandex.skipasssystem.skipass.validators.Validator;

import java.time.LocalDate;

public abstract class SkiPass {
    private long id;
    private LocalDate fromDate;
    private LocalDate toDate;
    private boolean isActive = true;

    SkiPass(long id,
            LocalDate fromDate,
            LocalDate toDate) {
        this.id = id;
        this.fromDate = fromDate;
        this.toDate = toDate;
    }

    public long getId() {
        return id;
    }

    public LocalDate getFromDate() {
        return fromDate;
    }

    public LocalDate getToDate() {
        return toDate;
    }

    public boolean isActive() {
        return isActive;
    }

    public void setActive(boolean isActive) {
        this.isActive = isActive;
    }

    public abstract Validator getValidator();

}
